Optimal. Leaf size=75 \[ -\frac{2 b \text{EllipticF}\left (\frac{1}{2} (c+d x),2\right )}{a^2 d}+\frac{2 b^2 \Pi \left (\frac{2 a}{a+b};\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 d (a+b)}+\frac{2 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.242028, antiderivative size = 75, normalized size of antiderivative = 1., number of steps used = 9, number of rules used = 8, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.348, Rules used = {4264, 3852, 3849, 2805, 3787, 3771, 2639, 2641} \[ \frac{2 b^2 \Pi \left (\frac{2 a}{a+b};\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 d (a+b)}-\frac{2 b F\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 d}+\frac{2 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4264
Rule 3852
Rule 3849
Rule 2805
Rule 3787
Rule 3771
Rule 2639
Rule 2641
Rubi steps
\begin{align*} \int \frac{\sqrt{\cos (c+d x)}}{a+b \sec (c+d x)} \, dx &=\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{1}{\sqrt{\sec (c+d x)} (a+b \sec (c+d x))} \, dx\\ &=\frac{\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{a-b \sec (c+d x)}{\sqrt{\sec (c+d x)}} \, dx}{a^2}+\frac{\left (b^2 \sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{\sec ^{\frac{3}{2}}(c+d x)}{a+b \sec (c+d x)} \, dx}{a^2}\\ &=\frac{b^2 \int \frac{1}{\sqrt{\cos (c+d x)} (b+a \cos (c+d x))} \, dx}{a^2}+\frac{\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{1}{\sqrt{\sec (c+d x)}} \, dx}{a}-\frac{\left (b \sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \sqrt{\sec (c+d x)} \, dx}{a^2}\\ &=\frac{2 b^2 \Pi \left (\frac{2 a}{a+b};\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 (a+b) d}+\frac{\int \sqrt{\cos (c+d x)} \, dx}{a}-\frac{b \int \frac{1}{\sqrt{\cos (c+d x)}} \, dx}{a^2}\\ &=\frac{2 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}-\frac{2 b F\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 d}+\frac{2 b^2 \Pi \left (\frac{2 a}{a+b};\left .\frac{1}{2} (c+d x)\right |2\right )}{a^2 (a+b) d}\\ \end{align*}
Mathematica [A] time = 0.291558, size = 84, normalized size = 1.12 \[ -\frac{2 \sin (c+d x) \left (-(a+b) \text{EllipticF}\left (\sin ^{-1}\left (\sqrt{\cos (c+d x)}\right ),-1\right )-b \Pi \left (-\frac{a}{b};\left .-\sin ^{-1}\left (\sqrt{\cos (c+d x)}\right )\right |-1\right )+a E\left (\left .\sin ^{-1}\left (\sqrt{\cos (c+d x)}\right )\right |-1\right )\right )}{a^2 d \sqrt{\sin ^2(c+d x)}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 1.507, size = 226, normalized size = 3. \begin{align*} 2\,{\frac{\sqrt{ \left ( 2\, \left ( \cos \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}-1 \right ) \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}}\sqrt{ \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}}\sqrt{-2\, \left ( \cos \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}+1}}{ \left ( a-b \right ){a}^{2}\sqrt{-2\, \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}+ \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}}\sin \left ( 1/2\,dx+c/2 \right ) \sqrt{2\, \left ( \cos \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}-1}d} \left ({\it EllipticF} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,\sqrt{2} \right ) ab-{\it EllipticF} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,\sqrt{2} \right ){b}^{2}+{\it EllipticE} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,\sqrt{2} \right ){a}^{2}-{\it EllipticE} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,\sqrt{2} \right ) ab+{b}^{2}{\it EllipticPi} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,2\,{\frac{a}{a-b}},\sqrt{2} \right ) \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{\cos \left (d x + c\right )}}{b \sec \left (d x + c\right ) + a}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{\cos{\left (c + d x \right )}}}{a + b \sec{\left (c + d x \right )}}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{\cos \left (d x + c\right )}}{b \sec \left (d x + c\right ) + a}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]